import request from "@/utils/request.js";

/**
 * 根据父级获取子级运营标签
 * @param params
 * @returns {AxiosPromise}
 */
export function listByParentId(params) {
  return request({
    closeLoading: true,
    url: "/operateService/api/operateTag/listByParentId",
    method: "post",
    data: params
  });
}

/**
 * 获取一级运营标签列表
 * @param params
 * @returns {AxiosPromise}
 */
export function listLevelOne(params) {
  return request({
    closeLoading: true,
    url: "/operateService/api/operateTag/listLevelOne",
    method: "post",
    data: params
  });
}

/**
 * 获取二级运营标签列表
 * @param params
 * @returns {AxiosPromise}
 */
export function listLevelSecond(params) {
  return request({
    closeLoading: true,
    url: "/operateService/api/operateTag/listLevelSecond",
    method: "post",
    data: params
  });
}

/**
 * 获取三级运营标签列表
 * @param params
 * @returns {AxiosPromise}
 */
export function listLevelThird(params) {
  return request({
    closeLoading: true,
    url: "/operateService/api/operateTag/listLevelThird",
    method: "post",
    data: params
  });
}

/**
 * 删除运营标签
 * @param params
 * @returns {AxiosPromise}
 */
export function remove(params) {
  return request({
    url: "/operateService/api/operateTag/remove",
    method: "post",
    data: params
  });
}

/**
 * 新增运营标签
 * @param params
 * @returns {AxiosPromise}
 */
export function save(params) {
  return request({
    url: "/operateService/api/operateTag/save",
    method: "post",
    data: params
  });
}

/**
 * 修改运营标签
 * @param params
 * @returns {AxiosPromise}
 */
export function update(params) {
  return request({
    url: "/operateService/api/operateTag/update",
    method: "post",
    data: params
  });
}

/**
 * 修改运营标签禁用/启用状态
 * @param params
 * @returns {AxiosPromise}
 */
export function updateUseFlag(params) {
  return request({
    url: "/operateService/api/operateTag/updateUseFlag",
    method: "post",
    data: params
  });
}

//全部方法
//listByParentId、listLevelOne、listLevelSecond、listLevelThird、remove、save、update、updateUseFlag
